package com.peanut.devlibrary.util;

import android.view.animation.Animation;
import android.view.animation.LinearInterpolator;
import android.view.animation.RotateAnimation;

/**
 * Created by anonymouslystudio on 2017/6/6.
 */

public class AnimUtil {

    /**
     *
     * @return
     */
    public static Animation getLoadingAnimation() {

        Animation mAnimation = new RotateAnimation(0.0f, 360.0f, RotateAnimation.RELATIVE_TO_SELF, 0.5f, RotateAnimation.RELATIVE_TO_SELF, 0.5f);
        mAnimation.setDuration(500);
        mAnimation.setRepeatCount(-1);
        mAnimation.setInterpolator(new LinearInterpolator());

        return mAnimation;
    }
}
